<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Vue.js生命周期和Axios基础</title>
    <link rel="stylesheet" href="./styles/index.css">
</head>
<body>
    <main id="main">
        <table>
            <thead>
                <tr>
                    <th v-for="th in thArr">{{th}}</th>
                </tr>
            </thead>
            <tbody>
                <tr v-for="product in products">
                    <td>{{product.product_id}}</td>
                    <td>{{product.name}}</td>
                    <td>{{product.category}}</td>
                    <td>{{product.modelType}}</td>
                    <td 
                        class="lookup"
                        v-on:click="showContent(product)"
                    >详情</td>
                </tr>
            </tbody>
        </table>
        <div v-html="content"></div>
    </main>

    <script src="./plugins/vue.min.js"></script>
    <script src="./plugins/axios.min.js"></script>
    <script src="./scripts/index.js"></script>
</body>
</html>